/**
 * Copyright &copy; 2012-2016 <a href="https://istep.lczyfz.com">Istep</a> All rights reserved.
 */
package com.lczyfz.istep.modules.teach.dao;

import com.lczyfz.istep.common.persistence.CrudDao;
import com.lczyfz.istep.common.persistence.annotation.MyBatisDao;
import com.lczyfz.istep.modules.resource.entity.ResourcePaperQuestion;
import com.lczyfz.istep.modules.resource.entity.ResourceQuestionAnswer;
import com.lczyfz.istep.modules.teach.entity.TeachExam;
import com.lczyfz.istep.modules.teach.entity.TeachStudentPaper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 学生考试中间表DAO接口
 * @author cqh
 * @version 2017-05-16
 */
@MyBatisDao
public interface TeachStudentPaperDao extends CrudDao<TeachStudentPaper> {

    void deleteStudentAnswerByuserIdandPaperId(@Param("userId")String id,@Param("paperId")String paperId);
    public List<TeachStudentPaper> findStuAnswerList(@Param("id")String id,@Param("paperId")String paperId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

    public List<ResourcePaperQuestion> getScoreByPaperIdAndQuestionId(@Param("paperId")String paperId,@Param("questionId")String questionId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

    public List<ResourceQuestionAnswer> getRightAnswerByQuestionId(@Param("questionId")String questionId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

    public List<TeachStudentPaper> getAllScoreByUserIdAndPaperId(@Param("userId")String userId,@Param("paperId")String paperId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

    public List<TeachExam> getIfCheckAnswerByExamId(@Param("examId")String examId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

    public List<ResourceQuestionAnswer> getQuestionAnswerList(@Param("paperId")String paperId,@Param("DEL_FLAG_NORMAL")String DEL_FLAG_NORMAL);

}
